﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework.Content;
using Microsoft.Xna.Framework;
using Microsoft.Xna.Framework.Graphics;

namespace Imagine
{

   public class TheAssetManager
    {
        #region Private_Parts
        HotAssetLoader m_universalLoader;
        static TheAssetManager m_instance;
        #endregion

        TheAssetManager()
        {
            m_universalLoader = new HotAssetLoader(Engine.Instance().Content);
        }
        
        static public TheAssetManager Instance()
        {
            if(m_instance == null)
                m_instance = new TheAssetManager();
            return m_instance;
        }

        public T Load<T>(string path)
        {
            return m_universalLoader.Load<T>(path);
        }

        public void RefreshResources()
        {
            m_universalLoader.Refresh();
        }
 
    }
}
